/*
 * INSANE - Interactive Structural Analysis Environment
 *
 * Copyright (C) 2003-2006
 * Universidade Federal de Minas Gerais
 * Escola de Engenharia
 * Departamento de Engenharia de Estruturas
 *
 * Author's email :     insane@dees.ufmg.br
 * Author's Website :   http://www.dees.ufmg.br/insane
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version 2
 * of the License, or any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 *
 */

package br.ufmg.dees.insane.draw;

import java.awt.Color;
import java.awt.Graphics2D;
import java.awt.Point;
import java.awt.Rectangle;
import java.util.Vector;

/**
 * @author Fonseca, Flavio & Pitangueira, Roque
 * @since	April 2004
 */
public abstract class NodalLoadDraw extends Draw{
	
//	*******************************************************************************	

	public static class X extends NodalLoadDraw {
		Point p0;
		Point p1;
		Point p2;
		Point p3;
		
		public X(Point p0,Point p1,Point p2, Point p3) {
			this(p0);
			this.p0 = p0;
			this.p1 = p1;
			this.p2 = p2;
			this.p3 = p3;
		}
		
		public X(Point loc) {
			this(loc, null);
		}
		
		public X(Point loc, Object represents) {
			this.setLocation(loc);
			this.setRepresents(represents);
		}        
		
		public Vector<Object> getShapes() {
			return null;
		}
		
		
		/**
		 * Draws in a given Graphics.
		 * @see   java.awt.Graphics
		 */
		public void draw(Graphics2D g2) {
			g2.drawLine(p0.x,p0.y,p1.x,p1.y);
			g2.drawLine(p0.x,p0.y,p2.x,p2.y);
			g2.drawLine(p0.x,p0.y,p3.x,p3.y);
		} 
		
		/**
		 * Returns the draw bounds in device units.
		 * @return the draw bounds
		 */
		public Rectangle getBounds() {
			return null;
		}
		
	}//end of this class
	
//	*****************************************************************************		    
	
	public static class Y extends NodalLoadDraw {
		Point p0;
		Point p1;
		Point p2;
		Point p3;
		
		public Y(Point p0,Point p1,Point p2, Point p3) {
			this(p0);
			this.p0 = p0;
			this.p1 = p1;
			this.p2 = p2;
			this.p3 = p3;
		}
		
		public Y(Point loc) {
			this(loc, null);
		}
		
		public Y(Point loc, Object represents) {
			this.setLocation(loc);
			this.setRepresents(represents);
		}        
		
		public Vector<Object> getShapes() {
			return null;
		}
		
		
		/**
		 * Draws in a given Graphics.
		 * @see   java.awt.Graphics
		 */
		public void draw(Graphics2D g2) {
			g2.drawLine(p0.x,p0.y,p1.x,p1.y);
			g2.drawLine(p0.x,p0.y,p2.x,p2.y);
			g2.drawLine(p0.x,p0.y,p3.x,p3.y);
		} 
		
		/**
		 * Returns the draw bounds in device units.
		 * @return the draw bounds
		 */
		public Rectangle getBounds() {
			return null;
		}
		
	}//end of this class
	
//	*****************************************************************************	
	
	public static class Z extends NodalLoadDraw {
		Point p0;
		Point p1;
		Point p2;
		Point p3;
		
		public Z(Point p0,Point p1,Point p2, Point p3) {
			this(p0);
			this.p0 = p0;
			this.p1 = p1;
			this.p2 = p2;
			this.p3 = p3;
		}
		
		public Z(Point loc) {
			this(loc, null);
		}
		
		public Z(Point loc, Object represents) {
			this.setLocation(loc);
			this.setRepresents(represents);
		}        
		
		public Vector<Object> getShapes() {
			return null;
		}
		
		
		/**
		 * Draws in a given Graphics.
		 * @see   java.awt.Graphics
		 */
		public void draw(Graphics2D g2) {
			g2.drawLine(p0.x,p0.y,p1.x,p1.y);
			g2.drawLine(p0.x,p0.y,p2.x,p2.y);
			g2.drawLine(p0.x,p0.y,p3.x,p3.y);
		} 
		
		/**
		 * Returns the draw bounds in device units.
		 * @return the draw bounds
		 */
		public Rectangle getBounds() {
			return null;
		}
		
	}//end of this class

//	*****************************************************************************	
	

	public static class MX extends NodalLoadDraw {
		Point p0;
		Point p1;
		Point p2;
		Point p3;
		Point p4;
		Point p5;
		Point p6;
		
		public MX(Point[] pd) {
			this(pd[0]);
			this.p0 = pd[0];
			this.p1 = pd[1];
			this.p2 = pd[2];
			this.p3 = pd[3];
			this.p4 = pd[4];
			this.p5 = pd[5];
			this.p6 = pd[6];
		}
		
		public MX(Point loc) {
			this(loc, null);
		}
		
		public MX(Point loc, Object represents) {
			this.setLocation(loc);
			this.setRepresents(represents);
		}        
		
		public Vector<Object> getShapes() {
			return null;
		}
		
		/**
		 * Draws in a given Graphics.
		 * @see   java.awt.Graphics
		 */
		public void draw(Graphics2D g2) {
			Color green = new Color(0.0f,1.0f,0.0f);
			g2.setColor(green);
			g2.drawLine(p0.x,p0.y,p6.x,p6.y);
			g2.drawLine(p0.x,p0.y,p1.x,p1.y);
			g2.drawLine(p0.x,p0.y,p2.x,p2.y);
			g2.drawLine(p3.x,p3.y,p4.x,p4.y);
			g2.drawLine(p3.x,p3.y,p5.x,p5.y);
		} 
		
		/**
		 * Returns the draw bounds in device units.
		 * @return the draw bounds
		 */
		public Rectangle getBounds() {
			return null;
		}
		
	}//end of this class

//	*****************************************************************************	
	
	public static class MY extends NodalLoadDraw {
		Point p0;
		Point p1;
		Point p2;
		Point p3;
		Point p4;
		Point p5;
		Point p6;
		
		public MY(Point[] pd) {
			this(pd[0]);
			this.p0 = pd[0];
			this.p1 = pd[1];
			this.p2 = pd[2];
			this.p3 = pd[3];
			this.p4 = pd[4];
			this.p5 = pd[5];
			this.p6 = pd[6];
		}
		
		public MY(Point loc) {
			this(loc, null);
		}
		
		public MY(Point loc, Object represents) {
			this.setLocation(loc);
			this.setRepresents(represents);
		}        
		
		public Vector<Object> getShapes() {
			return null;
		}
		
		/**
		 * Draws in a given Graphics.
		 * @see   java.awt.Graphics
		 */
		public void draw(Graphics2D g2) {
			Color green = new Color(0.0f,1.0f,0.0f);
			g2.setColor(green);
			g2.drawLine(p0.x,p0.y,p6.x,p6.y);
			g2.drawLine(p0.x,p0.y,p1.x,p1.y);
			g2.drawLine(p0.x,p0.y,p2.x,p2.y);
			g2.drawLine(p3.x,p3.y,p4.x,p4.y);
			g2.drawLine(p3.x,p3.y,p5.x,p5.y);
		} 
		
		/**
		 * Returns the draw bounds in device units.
		 * @return the draw bounds
		 */
		public Rectangle getBounds() {
			return null;
		}
		
	}//end of this class

//	*****************************************************************************	
	
	public static class MZ extends NodalLoadDraw {
		Point p0;
		Point p1;
		Point p2;
		Point p3;
		Point p4;
		Point p5;
		Point p6;
		
		public MZ(Point[] pd) {
			this(pd[0]);
			this.p0 = pd[0];
			this.p1 = pd[1];
			this.p2 = pd[2];
			this.p3 = pd[3];
			this.p4 = pd[4];
			this.p5 = pd[5];
			this.p6 = pd[6];
		}
		
		public MZ(Point loc) {
			this(loc, null);
		}
		
		public MZ(Point loc, Object represents) {
			this.setLocation(loc);
			this.setRepresents(represents);
		}        
		
		public Vector<Object> getShapes() {
			return null;
		}
		
		/**
		 * Draws in a given Graphics.
		 * @see   java.awt.Graphics
		 */
		public void draw(Graphics2D g2) {
			Color green = new Color(0.0f,1.0f,0.0f);
			g2.setColor(green);
			g2.drawLine(p0.x,p0.y,p6.x,p6.y);
			g2.drawLine(p0.x,p0.y,p1.x,p1.y);
			g2.drawLine(p0.x,p0.y,p2.x,p2.y);
			g2.drawLine(p3.x,p3.y,p4.x,p4.y);
			g2.drawLine(p3.x,p3.y,p5.x,p5.y);
		} 
		
		/**
		 * Returns the draw bounds in device units.
		 * @return the draw bounds
		 */
		public Rectangle getBounds() {
			return null;
		}
	}//end of this class

//	*****************************************************************************	
}
